﻿// Decompiled by AS3 Sorcerer 6.78
// www.buraks.com/as3sorcerer

//com.wdcgame.tile.Circle

package com.game.tile
{
    import flash.display.Sprite;

    public class Circle extends Sprite 
    {

        private var _radius:Number;
        private var _color:uint;
        private var _isOn:Boolean = false;

        public function Circle(_arg_1:Number, _arg_2:uint=0xFF)
        {
            _radius = _arg_1;
            _color = _arg_2;
            graphics.lineStyle(1, _color);
            graphics.beginFill(0xCCCCCC, 0.5);
            graphics.drawCircle(0, 0, _radius);
            graphics.drawCircle(0, 0, 3);
            graphics.endFill();
        }

        public function get radius():Number
        {
            return (_radius);
        }

        public function light():void
        {
            if (!_isOn)
            {
                graphics.lineStyle(1, 0xFF0000);
                graphics.drawCircle(0, 0, _radius);
            }
            _isOn = true;
        }

        public function off():void
        {
            if (_isOn)
            {
                graphics.lineStyle(1, _color);
                graphics.drawCircle(0, 0, _radius);
            }
            _isOn = false;
        }


    }
}//package com.wdcgame.tile

